package com.chunguang.study;

import java.util.Date;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import com.chunguang.study.bean.RoncooUser;
import com.chunguang.study.mapper.RoncooUserMapper;

@RunWith(SpringRunner.class)
@SpringBootTest
public class RedisCacheTests2 {

	@Autowired
	private RoncooUserMapper mapper;

//	@Test
//	public void insert() {
//		RoncooUser roncooUser = new RoncooUser();
//		roncooUser.setId(2);
//		roncooUser.setName("测试");
//		roncooUser.setCreateTime(new Date());
//		int result = mapper.insert(roncooUser);
//		System.out.println(result);
//	}
//	
	@Test
	public void select() {
		RoncooUser result = mapper.selectByPrimaryKey(1);
		RoncooUser result2 = mapper.selectByPrimaryKey(1);
		System.out.println(result);
	}

}
